package io;

import configuration.Configuration;

public class InputOutputFactory {
	
	public InputOutput newInputOutput(){
		Configuration config = Configuration.getInstance(); 
		if(config.getInputOutputType() == Configuration.CONSOLE){
			ConsoleInputOutput console = new ConsoleInputOutput(); 
			return console; 
		}
		if(config.getInputOutputType() == Configuration.MOCK){
			MockInputOutput mimic = new MockInputOutput(); 
			return mimic; 
		}
		if(config.getInputOutputType() == Configuration.GUI){
			GUIInputOutput gui = new GUIInputOutput(); 
			return gui; 
		}
		return null; 
	}

}
